package com.fifth.apartment.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.fifth.apartment.entity.Permission;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.Set;

@Mapper
public interface PermissionMapper extends BaseMapper<Permission> {

    @Select("select * from permission pe,role_permission rp where pe.id = rp.permission_id and rp.role_id = #{id}")
    Set<Permission> queryPermissiomById(Integer id);
}
